import { $http } from '../index';

export function getCreativeList(data = {}) {
    return $http.post('/saas/creative/list', data);
}

// 投放主体查询
export function getcompanyInfo(companyName: string) {
    return $http.get(`/saas/customer/companyName?companyName=${companyName}`);
}

// 新增创意
export function addOrUpdate(data = {}) {
    return $http.post('/saas/creative/addOrUpdate', data);
}

// 详情
export function getDetail(id: string) {
    return $http.get(`/saas/creative/detail/${id}`);
}

// 投放主体查询
export function getCompanyInfo(deliverSubject: string) {
    return $http.get(`/saas/rpc/crmCustomer/${deliverSubject}`);
}

export function getQualificationConf() {
    return $http.get('/saas/rpc/ad-qualification-conf');
}
// 方案关联创意查询
export function searchCreativeList(data = {}) {
    return $http.post('/saas/creative/creative-name-list', data);
}
